home *** CD-ROM | disk | FTP | other *** search
Text File | 1989-11-15 | 1.5 KB | 36 lines | [TEXT/pdos] |
- Apple II
- Technical Notes
- _____________________________________________________________________________
- Developer Technical Support
-
-
- Apple IIGS
- #60: Care and Feeding of NewMenu
-
- Written by: Dave Lyons July 1989
-
- This Technical Note discusses NewMenu in System Software 5.0 and earlier,
- where it does not expect its string parameter to cross a bank boundary. Make
- sure it doesn't.
- _____________________________________________________________________________
-
- NewMenu takes a pointer to a string; this string must not cross a bank
- boundary. If it does, a menu containing random garbage may result.
-
- If your NewMenu strings are contained in your code segments, everything is
- fine--code segments cannot cross bank boundaries. Depending on your
- development environment, strings that are not in a code segment may or may not
- be allowed to cross bank boundaries. If you can find no other way to
- guarantee the strings will not cross a bank boundary, use NewHandle to
- allocate blocks with attributes $4010 (fixed, no bank cross) and copy the
- strings to these blocks.
-
- If you create menus from resources, be sure the resources have their
- noBankCross attribute bits set. Note that a memory block that can cross a
- bank boundary usually does not, so your application may be working by
- accident.
-
-
- Further Reference
- _____________________________________________________________________________
- o Apple IIGS Toolbox Reference, Volume 1